
from WtfGui import *;
from WtfEngine import *;

class WtfPaintWindow(Window):
	def __init__(self):
		Window.__init__(self, "WtfPaint");
		
		self.font = Font("v_gui_font");
		
		self.btnSave = Button(EventHandler(lambda e: self.save()), "Save", self.font);
		
		self.AddChild(btnSave);
	
	def open(self):
		
	def save(self):
		if(!hasattr(self, "fileName"))
			self.fileName = InputBox("Enter the file name to save to (including extension):");
		
		self.texImage.Write(self.fileName);
		
def Main(vArg):
	wm = vArg["wm"];
	
	wnd = WtfPaintWindow();
	wm.AddWindow(wnd, 1);
	